<template>
  <div id="online" class="container">
    <data-table ref="dtb" :api-setting="apiSetting" pagination>
      <el-table-column
        fixed
        prop="userid"
        label="UserId"
        show-overflow-tooltip
      />
      <el-table-column prop="usercode" label="账号" show-overflow-tooltip />
      <el-table-column prop="username" label="用户名" show-overflow-tooltip />
      <el-table-column prop="classname" label="班级名" show-overflow-tooltip />
      <el-table-column prop="deptname" label="院系名" show-overflow-tooltip />
      <el-table-column prop="schoolname" label="学校名" show-overflow-tooltip />
      <el-table-column
        prop="lastactivedate"
        label="最后活动时间"
        show-overflow-tooltip
      >
        <template slot-scope="{ row }">
          {{ row.lastactivedate | formatterDate }}
        </template>
      </el-table-column>
    </data-table>
  </div>
</template>

<script>
import dtb from "../../mixins/refs/dtb";

export default {
  name: "index",
  mixins: [dtb],
  data() {
    return {
      apiSetting: {
        method: "post",
        url: "/sys/user/getOnlineUser",
        data: {}
      }
    };
  }
};
</script>

<style scoped></style>
